<?php
// +----------------------------------------------------------------------
// | ThinkPHP [ WE CAN DO IT JUST THINK ]
// +----------------------------------------------------------------------
// | Copyright (c) 2006~2018 http://thinkphp.cn All rights reserved.
// +----------------------------------------------------------------------
// | Licensed ( http://www.apache.org/licenses/LICENSE-2.0 )
// +----------------------------------------------------------------------
// | Author: liu21st <liu21st@gmail.com>
// +----------------------------------------------------------------------

use think\Route;
//admin
Route::get('delrode/:id','admin/roles/delrole');
Route::get('delnode/:id','admin/nodes/delnode');
Route::get('editnode/:id','admin/nodes/showedit');
Route::get('rolestatus1/:id','admin/roles/changestatus1');
Route::get('rolestatus2/:id','admin/roles/changestatus2');
Route::get('adminstatus1/:id','admin/admins/changestatus1');
Route::get('adminstatus2/:id','admin/admins/changestatus2');
Route::get('partstatus1/:id','admin/part/partstatus1');
Route::get('partstatus2/:id','admin/part/partstatus2');
Route::get('deladmin/:id','admin/admins/deladmin');
Route::post('login','admin/login/login');

Route::post('doadd','admin/user/doadd');
Route::get('userstatus1/:id','admin/user/userstatus1');
Route::get('userstatus2/:id','admin/user/userstatus2');

Route::post('addsoncate/:id','admin/cates/addsoncate');
Route::post('showcate/:id','admin/cates/cateist');
Route::post('editcate/:id','admin/cates/editcate');
Route::get('delcate/:id','admin/cates/delcate');
Route::get('delpart/:id','admin/part/delpart');

//index
Route::post('user_login','index/login/userlogin');
// Route::get('login','index/login/index');
Route::post('company_login','index/login/companylogin');
Route::get('resetpwd/:id','index/login/passwordreset');
// Route::post('ednode/:id','admin/Nodes/editNode');

//company
Route::get('companystatus1/:id','admin/companys/changestatus1');
Route::get('companystatus2/:id','admin/companys/changestatus2');
Route::get('delcompany/:id','admin/companys/delcompany');
Route::get('message/:id','index/index/message');

return [
    '__pattern__' => [
        'name' => '\w+',
    ],
    '[hello]'     => [
        ':id'   => ['index/hello', ['method' => 'get'], ['id' => '\d+']],
        ':name' => ['index/hello', ['method' => 'post']],
    ],

];
